home *** CD-ROM | disk | FTP | other *** search
- /*
-
- File: CAS_Globals.h
-
- Contains: theDoc variables declarations, defines, and typedefs.
-
- Written by: David H Nelson
-
- Copyright © 1993-1995 ComponentWorks, All rights reserved.
-
- Change History (most recent first):
-
- <2> 4/23/95 RB Added gAppMenuBar
- <1> 11/20/93 DHN Created.
-
- */
-
- #if !defined(_H_CAS_Globals)
- #define _H_CAS_Globals
-
- #include <Drag.h>
- #include "CAS_Misc.h"
- #include "CAS_App.h"
-
-
- #include "TraceLog.h"
-
- //#if defined(__MIXEDMODE__) || !defined(THINK_C)
- //#include <Printing.h>
- //#endif
-
- #undef GLOBAL
- #ifdef _MAIN_
- #define GLOBAL
- #else
- #define GLOBAL extern
- #endif
-
-
- //----------------------------------------------------------------------
- #define kWindowID 128
-
- // Dialog Resource ID's
- #define kSaveChangesDialog 129
- #define kGetInfoDialog 131
- #define kPreferencesDialog 132
- #define kErrorDialog 133
- #define kPrintStatusDialog 135
-
- #define handCursor 128
-
- #define kOKButton 1
- #define kCancelButton 2
-
- #define kSaveButton 1
- #define kDontSaveButton 3
-
- #define SBARWIDTH 16
-
- // Miscellaneous String Resources
-
- #define kStrings 1000
-
- typedef enum
- {
- itOurPrefName = 1,
- itClosing,
- itQuitting,
- itSavePrompt,
- itUntitled
- }
- StrIndexes;
-
- //---------------------------------------------------------------------------
- // Constants
-
- #define kPICTType 'PICT'
-
-
- //---------------------------------------------------------------------------
-
- // These are the globals for the application.
-
- GLOBAL Boolean gExitFlag;
- GLOBAL Boolean gInBackground;
- GLOBAL Boolean gOptionPressed;
- GLOBAL Boolean gShiftPressed;
- GLOBAL Boolean gCmdPressed;
- GLOBAL Boolean gControlPressed;
- GLOBAL long gMouseUpTickCount;
- GLOBAL Point gMouseUpPoint;
-
- GLOBAL unsigned long gSleepTime; // current sleep value for WaitNextEvent
- GLOBAL RgnHandle gMouseRgn; // current mouse-moved rgn for WaitNextEvent
-
- GLOBAL short gPrefRefNum; // refnum of pref res file
- GLOBAL Boolean gPrefChanged; // true when a pref value changes
- GLOBAL Boolean gPrefSampleFlag; // a sample pref flag to save
-
- GLOBAL unsigned long gWindowCount; // Count of new windows for naming new untitled windows.
-
- GLOBAL Handle gAppMenuBar;
- GLOBAL AppPtr gAppPtr;
-
- // aplication specific globals
- GLOBAL ModalFilterUPP gWindowEventFilterUPP;
- GLOBAL ModalFilterYDUPP gWindowEventFilterYDUPP;
- GLOBAL GrowZoneUPP gGrowZoneUPP;
- GLOBAL ControlActionUPP gScrollBarActionUPP;
- GLOBAL DragReceiveHandlerUPP gDragReceiveHandlerUPP;
- GLOBAL DragTrackingHandlerUPP gDragTrackingHandlerUPP;
- GLOBAL DragSendDataUPP gDragSendProcUPP;
-
- #ifdef USE_CALIB
- GLOBAL DlgHookYDUPP gDlgHookYDUPP;
- GLOBAL Boolean gCALibExists;
- GLOBAL Boolean gAppInForeGround;
- GLOBAL CADocumentRef gFocusDocument;
- #endif
-
- GLOBAL short gCurrentTool; // the current tool we are using.
- GLOBAL Handle gSplatsnd; // handle to sound for flipping pages.
-
- GLOBAL PicHandle gItemPICT[4]; // pictures
-
-
- #endif
-